link=-lpthread -ljsoncpp
#用命令行进行宏定义设置序列化方法
#method=-DDIY
all:cal_server.out cal_client.out
cal_client.out:client.cc client.hh
	g++ -o $@ $^ $(link) $(method) -std=c++11
cal_server.out:server.cc server.hh
	g++ -o $@ $^ $(link) $(method) -std=c++11
.PHONY:clean
clean:
	rm ./*.out